package com.muyi.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.muyi.mapper.TagPaperMapper;
import com.muyi.pojo.entity.TagPaper;
import com.muyi.pojo.entity.TagPaper;
import com.muyi.service.TagPaperService;
import com.muyi.mapper.TagPaperMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author VRMMO
 * @description 针对表【tag_paper】的数据库操作Service实现
 * @createDate 2025-06-11 15:04:41
 */
@Service
public class TagPaperServiceImpl extends ServiceImpl<TagPaperMapper, TagPaper>
        implements TagPaperService{
    @Autowired
    private TagPaperMapper tagPaperMapper;

    @Override
    public List<TagPaper> list() {
        return tagPaperMapper.list();
    }

    @Override
    public void delete(Integer category_tag_id) {
        tagPaperMapper.deleteById(category_tag_id);
    }

    @Override
    public void add(TagPaper TagPaper) {
        tagPaperMapper.insertAll(TagPaper);
    }

    @Override
    public void update(TagPaper TagPaper) {
        tagPaperMapper.update(TagPaper);
    }

    @Override
    public TagPaper getByTagPaperId(Integer category_tag_id) {
        return tagPaperMapper.getByTagPaperId(category_tag_id);
    }

}




